import { useState } from 'react'

export function useToggle(){

    const [value,setState] = useState(true)

    function toggle(){
        setState(!value)
    }
    return {
        value,
        toggle
    }

}